package com.mine.modules.vm.entity;

import com.baomidou.mybatisplus.annotation.*;

import java.io.Serializable;
import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * <p>
 * 场景菜单
 * </p>
 *
 * @author author
 * @since 2024-10-18
 */
@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("vm_layer_element")
@ApiModel(value = "VmLayerElement对象", description = "场景菜单")
public class VmLayerElement implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键id")
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private String id;

    @ApiModelProperty(value = "图层id")
    private String layerId;

    @ApiModelProperty(value = "图元id")
    private String elementId;

    @ApiModelProperty(value = "图元标识")
    private String elementCode;

    @ApiModelProperty(value = "图元名称")
    private String elementName;

    @ApiModelProperty(value = "图元类型")
    private String elementType;

    @ApiModelProperty(value = "场景图层id")
    @TableField(updateStrategy= FieldStrategy.IGNORED)
    private String sceneLayerId;

    @ApiModelProperty(value = "创建人")
    private String createBy;

    @ApiModelProperty(value = "创建时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    @ApiModelProperty(value = "更新人")
    private String updateBy;

    @ApiModelProperty(value = "更新时间")
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

    public VmLayerElement() {
    }

    public VmLayerElement(String layerId, String elementId, String elementCode, String elementName, String sceneLayerId, String elementType) {
        this.layerId = layerId;
        this.elementId = elementId;
        this.elementCode = elementCode;
        this.elementName = elementName;
        this.sceneLayerId = sceneLayerId;
        this.elementType = elementType;
    }
}
